home *** CD-ROM | disk | FTP | other *** search
- onClipEvent(enterFrame){
- if(_name != "shipP")
- {
- _Y = _Y + yspeed;
- if(_X < -100 || _X > 650 || _Y < -100 || _Y > 500 || _root.rem == true)
- {
- removeMovieClip(this);
- }
- var i = 0;
- while(i <= 20)
- {
- if(sh.harea.hitTest(_root["hmn" + i]))
- {
- life -= _root["hmn" + i].dmg;
- sh.play();
- removeMovieClip(_root["hmn" + i]);
- }
- i++;
- }
- if(_root.ship.sh.hitTest(sh.harea))
- {
- play();
- _root.ship.play();
- }
- if(life <= 0)
- {
- play();
- }
- yy = random(150);
- if(yy == 0 && _Y > 50 && _currentframe == 1 || _Y > 350 && _currentframe == 1)
- {
- this.gotoAndPlay("d");
- }
- }
- }
-